<ion-header>
    <ion-toolbar content-page>
        <ion-title (click)="showPushID()">
            首页
        </ion-title>
        <!--<ion-buttons end>-->
        <!--<button ion-button icon-only adpmenutoggle>-->
        <!--<i class="toolbar-menu"></i>-->
        <!--</button>-->
        <!--</ion-buttons>-->
    </ion-toolbar>
</ion-header>

<ion-content class="pageIndex">
    <ion-refresher (ionRefresh)="doRefresh($event)" [pullMax]="800">
        <ion-refresher-content></ion-refresher-content>
    </ion-refresher>

    <!--banner-->
    <div class="banner-warp" [class.empty]="bannerList.length==0">
        <div>
            <ion-slides #indexBanner pager>
                <ion-slide *ngFor="let item of bannerList" (click)="toBannerDetail(item)">
                    <div class="prevImg" *ngIf="item.isPrev">预览</div>
                    <img [src]="item.imgUrl" class="banner-slide-image" [alt]="item.title" [title]="item.title"/>
                </ion-slide>
            </ion-slides>
        </div>
    </div>
    <!-- 导航条 -->
    <div class="may-nav">
        <ion-slides pager #navSlides *ngIf="roles == '6' && agentLevel == 'FA'">
            <ion-slide>
                <ion-grid>
                    <ion-row>
                        <ion-col>
                            <span class="nav-item line-one" (click)="goMainPage('ClientIndexPage')">
                            <span class="item-icon"><i class="customer-yellow"></i></span>
                            <span class="item-text">客户</span>
                            </span>
                        </ion-col>
                        <ion-col>
                             <span class="nav-item line-one" (click)="goMainPage('PolicyListPage')">
                            <span class="item-icon"><i class="policy-green"></i></span>
                            <span class="item-text">保单</span>
                            </span>
                        </ion-col>
                        <ion-col>
                             <span class="nav-item line-one" (click)="goMainPage('MePage')">
                            <span class="item-icon"><i class="achieve-yellow"></i></span>
                            <span class="item-text">业绩</span>
                            </span>
                        </ion-col>
                        <ion-col>
                             <span class="nav-item line-one" (click)="goMainPage('TeamTeamIncreasePage')">
                            <span class="item-icon"><i class="add-customer-green"></i></span>
                            <span class="item-text">增员</span>
                            </span>
                        </ion-col>
                    </ion-row>
                    <ion-row>
                        <ion-col>
                            <span class="nav-item line-two" (click)="goMainPage('ActivityListPage')">
                            <span class="item-icon"><i class="activity-green"></i></span>
                            <span class="item-text">活动</span>
                            </span>
                        </ion-col>
                        <ion-col>
                             <span class="nav-item line-two" (click)="goMainPage('WebcastIndexPage')">
                            <span class="item-icon"><i class="live-yellow"></i></span>
                            <span class="item-text">直播</span>
                            </span>
                        </ion-col>
                        <ion-col>
                             <span class="nav-item line-two" (click)="goMainPage('InformationListPage')">
                            <span class="item-icon"><i class="news-green"></i></span>
                            <span class="item-text">资讯</span>
                            </span>
                        </ion-col>
                        <ion-col>
                             <span class="nav-item line-two" (click)="goMainPage('MessageOverviewPage')">
                                 <span *ngIf="unReadMsg > 0" class="item-circle"></span>
                                 <span class="item-icon"><i class="message-yellow"></i></span>
                            <span class="item-text">消息</span>
                            </span>
                        </ion-col>
                    </ion-row>
                </ion-grid>
            </ion-slide>
            <ion-slide>
                <ion-grid>
                    <ion-row>
                        <ion-col>
                            <span class="nav-item line-one" (click)="goMainPage('ScheduleListPage')">
                            <span class="item-icon"><i class="calendar-yellow"></i></span>
                            <span class="item-text">日程</span>
                            </span>
                        </ion-col>
                        <ion-col>
                             <span class="nav-item line-one" (click)="goMainPage('SettingPage')">
                            <!--<span *ngIf="unReadMsg > 0" class="item-circle"></span>-->
                                 <span class="item-icon"><i class="settings-green"></i></span>
                            <span class="item-text">设置</span>
                            </span>

                        </ion-col>
                        <ion-col>
                             <span class="nav-item line-one">
                            <span class="item-icon"><i></i></span>
                            <span class="item-text"></span>
                            </span>
                        </ion-col>
                        <ion-col>
                             <span class="nav-item line-one">
                            <span class="item-icon"><i></i></span>
                            <span class="item-text"></span>
                            </span>
                        </ion-col>
                    </ion-row>
                    <ion-row>
                        <ion-col>
                            <span class="nav-item line-two">
                            <span class="item-icon"><i></i></span>
                            <span class="item-text"></span>
                            </span>
                        </ion-col>
                        <ion-col>
                             <span class="nav-item line-two">
                            <span class="item-icon"><i></i></span>
                            <span class="item-text"></span>
                            </span>
                        </ion-col>
                        <ion-col>
                             <span class="nav-item line-two">
                            <span class="item-icon"><i></i></span>
                            <span class="item-text"></span>
                            </span>
                        </ion-col>
                        <ion-col>
                             <span class="nav-item line-two">
                            <span class="item-icon"><i></i></span>
                            <span class="item-text"></span>
                            </span>
                        </ion-col>
                    </ion-row>
                </ion-grid>
            </ion-slide>
        </ion-slides>
        <ion-slides pager #navSlides *ngIf="roles == '6' && agentLevel != 'FA'">
            <ion-slide>
                <ion-grid>
                    <ion-row>
                        <ion-col>
                            <span class="nav-item line-one" (click)="goMainPage('ClientIndexPage')">
                            <span class="item-icon"><i class="customer-yellow"></i></span>
                            <span class="item-text">客户</span>
                            </span>
                        </ion-col>
                        <ion-col>
                             <span class="nav-item line-one" (click)="goMainPage('PolicyListPage')">
                            <span class="item-icon"><i class="policy-green"></i></span>
                            <span class="item-text">保单</span>
                            </span>
                        </ion-col>
                        <ion-col>
                             <span class="nav-item line-one" (click)="goMainPage('MePage')">
                            <span class="item-icon"><i class="achieve-yellow"></i></span>
                            <span class="item-text">业绩</span>
                            </span>
                        </ion-col>
                        <ion-col>
                             <span class="nav-item line-one" (click)="goMainPage('TeamIndexPage')">
                            <span class="item-icon"><i class="team-green"></i></span>
                            <span class="item-text">团队</span>
                            </span>
                        </ion-col>
                    </ion-row>
                    <ion-row>
                        <ion-col>
                            <span class="nav-item line-two" (click)="goMainPage('TeamTeamIncreasePage')">
                            <span class="item-icon"><i class="add-customer-green"></i></span>
                            <span class="item-text">增员</span>
                            </span>
                        </ion-col>
                        <ion-col>
                             <span class="nav-item line-two" (click)="goMainPage('ActivityListPage')">
                            <span class="item-icon"><i class="activity-yellow"></i></span>
                            <span class="item-text">活动</span>
                            </span>
                        </ion-col>
                        <ion-col>
                             <span class="nav-item line-two" (click)="goMainPage('WebcastIndexPage')">
                            <span class="item-icon"><i class="live-green"></i></span>
                            <span class="item-text">直播</span>
                            </span>
                        </ion-col>
                        <ion-col>
                             <span class="nav-item line-two" (click)="goMainPage('MessageOverviewPage')">
                                 <span *ngIf="unReadMsg > 0" class="item-circle"></span>
                                 <span class="item-icon"><i class="message-yellow"></i></span>
                            <span class="item-text">消息</span>
                            </span>
                        </ion-col>
                    </ion-row>
                </ion-grid>
            </ion-slide>
            <ion-slide>
                <ion-grid>
                    <ion-row>
                        <ion-col>
                            <span class="nav-item line-one" (click)="goMainPage('InformationListPage')">
                            <span class="item-icon"><i class="news-yellow"></i></span>
                            <span class="item-text">资讯</span>
                            </span>
                        </ion-col>
                        <ion-col>
                              <span class="nav-item line-one" (click)="goMainPage('ScheduleListPage')">
                            <span class="item-icon"><i class="calendar-green"></i></span>
                            <span class="item-text">日程</span>
                            </span>
                        </ion-col>
                        <ion-col>
                             <span class="nav-item line-one" (click)="goMainPage('SettingPage')">
                            <!--<span *ngIf="unReadMsg > 0" class="item-circle"></span>-->
                                 <span class="item-icon"><i class="settings-yellow"></i></span>
                            <span class="item-text">设置</span>
                             </span>
                        </ion-col>
                        <ion-col>
                             <span class="nav-item line-one">
                            <span class="item-icon"><i></i></span>
                            <span class="item-text"></span>
                            </span>
                        </ion-col>
                    </ion-row>
                    <ion-row>
                        <ion-col>
                            <span class="nav-item line-two">
                            <span class="item-icon"><i></i></span>
                            <span class="item-text"></span>
                            </span>
                        </ion-col>
                        <ion-col>
                             <span class="nav-item line-two">
                            <span class="item-icon"><i></i></span>
                            <span class="item-text"></span>
                            </span>
                        </ion-col>
                        <ion-col>
                             <span class="nav-item line-two">
                            <span class="item-icon"><i></i></span>
                            <span class="item-text"></span>
                            </span>
                        </ion-col>
                        <ion-col>
                             <span class="nav-item line-two">
                            <span class="item-icon"><i></i></span>
                            <span class="item-text"></span>
                            </span>
                        </ion-col>
                    </ion-row>
                </ion-grid>
            </ion-slide>
        </ion-slides>
        <ion-slides #navSlides *ngIf="roles == '1'">
            <ion-slide>
                <ion-grid>
                    <ion-row>
                        <ion-col>
                            <span class="nav-item line-one" (click)="goMainPage('TeamIndexPage')">
                            <span class="item-icon"><i class="team-yellow"></i></span>
                            <span class="item-text">团队</span>
                            </span>
                        </ion-col>
                        <ion-col>
                             <span class="nav-item line-one" (click)="goMainPage('ActivityListPage')">
                            <span class="item-icon"><i class="activity-green"></i></span>
                            <span class="item-text">活动</span>
                            </span>
                        </ion-col>
                        <ion-col>
                             <span class="nav-item line-one" (click)="goMainPage('WebcastIndexPage')">
                            <span class="item-icon"><i class="live-yellow"></i></span>
                            <span class="item-text">直播</span>
                            </span>
                        </ion-col>
                        <ion-col>
                             <span class="nav-item line-one" (click)="goMainPage('ScheduleListPage')">
                            <span class="item-icon"><i class="calendar-green"></i></span>
                            <span class="item-text">日程</span>
                            </span>
                        </ion-col>
                    </ion-row>
                    <ion-row>
                        <ion-col>
                            <span class="nav-item line-two" (click)="goMainPage('InformationListPage')">
                            <span class="item-icon"><i class="news-green"></i></span>
                            <span class="item-text">资讯</span>
                            </span>
                        </ion-col>
                        <ion-col>
                             <span class="nav-item line-two" (click)="goMainPage('MessageOverviewPage')">
                                 <span *ngIf="unReadMsg > 0" class="item-circle"></span>
                            <span class="item-icon"><i class="message-yellow"></i></span>
                            <span class="item-text">消息</span>
                            </span>
                        </ion-col>
                        <ion-col>
                             <span class="nav-item line-two" (click)="goMainPage('SettingPage')">
                            <span class="item-icon"><i class="settings-green"></i></span>
                            <span class="item-text">设置</span>
                            </span>
                        </ion-col>
                        <ion-col>
                             <span class="nav-item line-two">
                                 <span class="item-icon"><i></i></span>
                            <span class="item-text"></span>
                            </span>
                        </ion-col>
                    </ion-row>
                </ion-grid>
            </ion-slide>
        </ion-slides>
        <ion-slides #navSlides *ngIf="roles == '2' || roles == '0' || roles == '3' || roles == '4' || roles == '5'">
            <ion-slide>
                <ion-grid>
                    <ion-row>
                        <ion-col>
                            <span class="nav-item line-one" (click)="goMainPage('ActivityListPage')">
                            <span class="item-icon"><i class="activity-yellow"></i></span>
                            <span class="item-text">活动</span>
                            </span>
                        </ion-col>
                        <ion-col>
                             <span class="nav-item line-one" (click)="goMainPage('ScheduleListPage')">
                            <span class="item-icon"><i class="calendar-green"></i></span>
                            <span class="item-text">日程</span>
                            </span>
                        </ion-col>
                        <ion-col>
                             <span class="nav-item line-one" (click)="goMainPage('WebcastIndexPage')">
                            <span class="item-icon"><i class="live-yellow"></i></span>
                            <span class="item-text">直播</span>
                            </span>
                        </ion-col>
                        <ion-col>
                             <span class="nav-item line-one" (click)="goMainPage('InformationListPage')">
                            <span class="item-icon"><i class="news-green"></i></span>
                            <span class="item-text">资讯</span>
                            </span>
                        </ion-col>
                    </ion-row>
                    <ion-row>
                        <ion-col>
                            <span class="nav-item line-two" (click)="goMainPage('MessageOverviewPage')">
                            <span *ngIf="unReadMsg > 0" class="item-circle"></span>
                                <span class="item-icon"><i class="message-green"></i></span>
                            <span class="item-text">消息</span>
                            </span>
                        </ion-col>
                        <ion-col>
                             <span class="nav-item line-two" (click)="goMainPage('SettingPage')">
                            <span class="item-icon"><i class="settings-yellow"></i></span>
                            <span class="item-text">设置</span>
                            </span>
                        </ion-col>
                        <ion-col>
                             <span class="nav-item line-two">
                            <span class="item-icon"><i></i></span>
                            <span class="item-text"></span>
                            </span>
                        </ion-col>
                        <ion-col>
                             <span class="nav-item line-two">
                                 <span class="item-icon"><i></i></span>
                            <span class="item-text"></span>
                            </span>
                        </ion-col>
                    </ion-row>
                </ion-grid>
            </ion-slide>
        </ion-slides>
    </div>

    <!--间距-->
    <p class="line-panel"></p>
    <!--头条-->
    <div class="top-msg-warp">
        <div class="top-msg-header">
            中宏头条
        </div>
        <div class="top-msg-middle">
            <ion-slides #topMsgSlide speed="2500">
                <ion-slide *ngFor="let item of topMsgList">
                    <div class="top-msg-middle-title" [innerHTML]="item.title"></div>
                </ion-slide>
            </ion-slides>
        </div>
        <div class="top-msg-last" (click)="toHeaderList()"></div>
    </div>
    <!--热点资讯-->
    <div id="hot-box" [class.empty]="hotList.length==0">
        <ion-slides #hotSlides slidesPerView="1.5" spaceBetween="15" speed="1000">
            <ion-slide *ngFor="let item of hotList ">
                <div class="prevImg" *ngIf="item.isPrev">预览</div>
                <img [src]="item.imgUrl" class="banner-slide-image" [alt]="item.title" [title]="item.title"
                     (click)="toDetailHeaderMsg(item)"/>
                <div class="hot-msg-title" [innerHTML]="item.title"></div>
            </ion-slide>
        </ion-slides>
    </div>
    <p class="line-panel"></p>
    <!--<div class="demo-img">-->
    <!--<img src="./assets/images/index/img_rc.png" alt="">-->
    <!--</div>-->

    <!-- 最近日程 -->
    <div class="calendar">
        <div class="calendar-title">
            <div class="title-left">
                最近日程
            </div>
            <div class="title-arrow" (click)="goMainPage('ScheduleListPage')"><i></i></div>
        </div>
        <div class="calendar-content left">
            <!--<div class="calendar-item normal-item special-background">-->
            <!--<span class="item-left">-->
            <!--<span class="time">今天 8:00 - 9:00</span>-->
            <!--<span class="customer">客户李先生过生日</span>-->
            <!--</span>-->
            <!--<span class="item-right">-->
            <!--<i></i>-->
            <!--</span>-->
            <!--</div>-->

            <!--<div class="calendar-item normal-item normal-background">-->
            <!--<span class="item-left gray">-->
            <!--<span class="time">今天 8:00 - 9:00</span>-->
            <!--<span class="customer">客户李先生过生日</span>-->
            <!--</span>-->
            <!--<span class="item-right">-->
            <!--<i></i>-->
            <!--</span>-->
            <!--</div>-->

            <!--<div class="calendar-item last-item normal-background">-->
            <!--<span class="item-left gray">-->
            <!--<span class="time">2018/06/05 10:30 - 11:30 （开始）</span>-->
            <!--<span class="time">2018/06/06 10:30 - 11:30 （结束）</span>-->
            <!--&lt;!&ndash;<span class="customer">客户李先生过生日</span>&ndash;&gt;-->
            <!--<span class="customer-sys"><span>[系统]</span> 客户李先生过生日</span>-->
            <!--</span>-->
            <!--<span class="item-right">-->
            <!--<i></i>-->
            <!--</span>-->
            <!--</div>-->
            <div class="calendar-item normal-item" (click)="goSheduleDetail(item.id, item)"
                 [ngClass]="{'normal-background': item.status == 'N', 'special-background': item.status == 'Y'}"
                 *ngFor="let item of sheduleList">
                <span class="item-left gray">
                    <span class="time" *ngIf="item.tags.length==1">{{item.tags[0]}}</span>
                    <span class="time" *ngIf="item.tags.length==2">{{item.tags[0]}}</span>
                    <span class="time" *ngIf="item.tags.length==2">{{item.tags[1]}}</span>
                    <span class="customer" *ngIf="item.type==1">{{item.name}}</span>
                    <span class="customer-sys" *ngIf="item.type != 1"><span class="tip">[系统]</span><span class="name">{{item.name}}</span></span>
                </span>
                <span class="item-right" *ngIf="item.reminder != 1">
                    <i></i>
                </span>
            </div>
        </div>

        <!--<div class="calendar-content center" *ngIf="sheduleList.length == 0">-->
        <!--<button class="calendar-add" (click)="goToAddSchedule()">添加日程</button>-->
        <!--</div>-->
        <div class="calendar-showbtn" *ngIf="sheduleList.length == 0">
            <button class="calendar-add" (click)="goToAddSchedule()">添加日程</button>
        </div>
    </div>

    <!--<p class="line-panel"></p>-->

    <!--<div class="customer">-->
    <!--<div class="customer-item">-->
    <!--<span class="item-left">-->
    <!--<span class="title">生日客户</span>-->
    <!--<span class="num">20</span>-->
    <!--</span>-->
    <!--<span class="item-right">-->
    <!--<span class="title">续期客户</span>-->
    <!--<span class="num">12</span>-->
    <!--</span>-->
    <!--</div>-->
    <!--</div>-->
</ion-content>
